import {defineConfig} from 'vite';
import vue from '@vitejs/plugin-vue';
import {link} from "./src/config/config.js";
import path from 'path'

export default ({mode}) => {
    return defineConfig({
        plugins: [vue()],
        base: link,
        assetsInclude: ['**/*.glb','**/*.hdr'],
        resolve: {
            alias: [
                {
                    find: '@',
                    replacement: path.resolve(__dirname, 'src')
                },
            ]
        },
        server: {
            port: 3033,
            open: true,
            overlay: {
                warnings: false,
                errors: true
            },
        },
    });
}
